// import http from './http'
// import { axios } from 'vue/types/umd'
import request from './request'

// 按需导出API   /index/index
// export const GetHomeData = () => http.get('/index/index')
//首页数据请求
export const GetHomeList = () => request.get("/index/index")

//获取搜索弹出框数据
export const GetSearchPopupData = () => request.get("/search/index")
//获取实时搜索的文本提示的数据列表
export const GetSearchTipsListData = (params) => request.get("/search/helper",{params})
// export const GetSearchTipsListData = params => request.get('/search/helper'{params})
// export const GetSearchTipsListData = (params) => request.get('/search/helper',{
//     params:params
// })
//获取搜索商品的数据
export const GetGoodsListData=(params)=>request.get("/goods/list",{params})
// post传参
// export const GetSearchTipsListData = params => request.get('/search/helper',params)
// axios.post('url',{
//     keyword:val//传递的参数
// })































// 进入popup时的请求，获取历史记录和热门搜索
// export const GetHistoryHotApi = () => http.get('/search/index')

// // 实时搜索功能
// export const GoSearchApi = (params) => http.get('/search/helper', { params })

// // 搜索框商品搜索
// export const SearchProductsApi = (params) => http.get('/goods/list', { params })

// // 产品明细
// export const GoodsDetailApi = (params) => http.get('/goods/detail', { params })

// // 相关产品
// export const GoodsRelatedApi = (params) => http.get('/goods/related', { params })

// // 登录
// export const LoginApi = (params) => http.post('/auth/loginByWeb', params)

// // 清除历史记录
// export const ClearHistoryApi = (params) => http.post('/search/clearhistory', params)

// // 获取购物车产品数量
// export const GoodsCountApi = () => http.get('/cart/goodscount')

// // 加入购物车
// export const AddToCartApi = (params) => http.post('/cart/add', params)

// // 获取购物车数据（含完成编辑）
// export const GetCartDataApi = () => http.get('/cart/index')

// // 点击切换商品选中状态（含全选）
// export const CartCheckedApi = (params) => http.post('/cart/checked', params)

// // 商品步进器
// export const StepChangeApi = (params) => http.post('/cart/update', params)

// // 删除商品
// export const CartDelApi = (params) => http.post('/cart/delete', params)

// // 专题页
// export const GetTopicApi = (params) => http.get('/topic/list', { params })

// // 全部分类数据接口
// export const GetChannelDataApi = () => http.get('/catalog/index')

// // 获取当前分类数据
// export const GetFenleiDataApi = (params) => http.get('/catalog/current', { params })

// // 分类数据获取
// export const GetCateGoryData = (params) => http.get('/goods/category', { params })

// // 分类页面商品列表请求
// export const GetCateGoryList = (params) => http.get('/goods/list', { params })

// // 品牌详情
// export const BrandDetailApi = (params) => http.get('/brand/detail', { params })